Builder

class Builder

A builder of File.

Builders are created by invoking newBuilder. Each of the setter methods modifies the state of the builder and returns the same instance. Builders are not thread-safe and should not be used concurrently from multiple threads without external synchronization.

Functions

Link copied to clipboard
open fun build(): File
Returns a new File instance built from the current state of this builder.
Link copied to clipboard
open fun bytesValue(bytes: Array<Byte>): File.Builder
Sets the byte sequence representing the file upload data segment.
Link copied to clipboard
open fun contentType(contentType: String): File.Builder
Sets the file content type determined by the file extension.
Link copied to clipboard
open fun name(name: String): File.Builder
Link copied to clipboard
open fun pathValue(path: Path): File.Builder
Sets the file path.